package jfxtras.scene.control;

import java.math.BigInteger;

/**
 * 
 * @author User
 *
 */
public class SpinnerXDataProviderYear 
implements SpinnerXDataProvider<BigInteger, BigInteger>
{
	@Override
	public BigInteger getPreviousIndex(BigInteger index)
	{
		return index.subtract(BigInteger.ONE);
	}

	@Override
	public BigInteger getNextIndex(BigInteger index)
	{
		return index.add(BigInteger.ONE);
	}

	@Override
	public BigInteger getValue(BigInteger index)
	{
		return index;
	}

	@Override
	public BigInteger getIndex(BigInteger value)
	{
		return value;
	}

	@Override
	public BigInteger addValue(BigInteger value)
	{
		return null; // adding not allowed
	}
}